#include "contact.h"

Contact::Contact(QWidget *parent) : QWidget(parent)
{
    EmailLabel = new QLabel(tr("电子邮件:"));
    EmailLineEdit = new QLineEdit;

    AddrLabel = new QLabel(tr("联系地址:"));
    AddrLineEdit = new QLineEdit;

    CodeLabel = new QLabel(tr("邮政编码:"));
    CodeLineEdit = new QLineEdit;

    MoviTelLabel = new QLabel(tr("移动电话:"));
    MoviTelLineEdit = new QLineEdit;
    MoviTeCheckBook = new QCheckBox(tr("接收留言:"));

    ProtelLabel = new QLabel(tr("办公电话:"));
    ProTelLineEdit = new QLineEdit;

    mailLayout = new QGridLayout(this);
    mailLayout->setMargin(15);
    mailLayout->setSpacing(10);
    mailLayout->addWidget(EmailLabel,0,0);
    mailLayout->addWidget(EmailLineEdit,0,1);
    mailLayout->addWidget(AddrLabel,1,0);
    mailLayout->addWidget(AddrLineEdit,1,1);
    mailLayout->addWidget(CodeLabel,2,0);
    mailLayout->addWidget(CodeLineEdit,2,1);
    mailLayout->addWidget(MoviTelLabel,3,0);
    mailLayout->addWidget(MoviTelLineEdit,3,1);
    mailLayout->addWidget(MoviTeCheckBook,3,2);
    mailLayout->addWidget(ProtelLabel,4,0);
    mailLayout->addWidget(ProTelLineEdit,4,1);
    mailLayout->setSizeConstraint(QLayout::SetFixedSize);

}
